package command.tv;

public class Test {
    public static void main(String[] args) {
        Television tv = new Television();
        Command open = new TvOpenCommand(tv);
        Command close = new TvCloseCommand(tv);
        Command volumeUp = new VolumeUpCommand(tv);
        Command volumeDown = new VolumeDownCommand(tv);
        Invoker invoker = new Invoker();

        invoker.addCommand(open);
        invoker.addCommand(volumeUp);
        invoker.addCommand(volumeUp);
        invoker.addCommand(volumeDown);
        invoker.invoke();
        invoker.undo();
    }
}